package com.bookSystem.entity;/*
 * @Author:lsx
 * @Date:2024/9/15--09--15--11:13
 *
 */

public class Book {
    private int bookId;
    private String name;
    private String type;
    private String author;

    // 构造方法
    public Book(int bookId, String name, String type, String author) {
        this.bookId = bookId;
        this.name = name;
        this.type = type;
        this.author = author;
    }
    // 构造方法
    public Book() {

    }
    // Getter 和 Setter 方法
    public int getBookId() {
        return bookId;
    }

    public void setBookId(int bookId) {
        this.bookId = bookId;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getAuthor() {
        return author;
    }

    public void setAuthor(String author) {
        this.author = author;
    }

    // toString 方法，用于输出对象的信息
    @Override
    public String toString() {
        return "Book{" +
                "bookId=" + bookId +
                ", name='" + name + '\'' +
                ", type='" + type + '\'' +
                ", author='" + author + '\'' +
                '}';
    }
}
